/**
 * Created by Administrator on 2017/4/22.
 */

var statement = require('../../../common/utils/MysqlStatement');

module.exports = {
  loginIn: function(param,callBack){
      var sql = {};
      sql.sqlStatement = 'select count(*) as count from userinfo where username = ? and userpass = ?';
      sql.arr = [param.username,param.userpass];

      statement.sqlStatement(sql,function(data){

          if(data.isSuccess && data.result[0].count > 0){
              callBack({
                  isSuccess:true
              });
          }else{
              callBack({
                  isSuccess:false
              });
          }

      });

  }
};
